function spinalCase(str) {
    return str
        .split(/(?=[A-Z])|\s+|-+|\_/)
        .join("-")
        .toLowerCase();
}

spinalCase("This Is Spinal Tap");
